package kr.hkit.PowerJava.chapter05.work;

import java.util.Scanner;

public class Moonje2 {
     public static void main(String[] args) {
    	 
    	 int a;
    	 int b;
    	   	 
    	 Scanner sc = new Scanner(System.in);
    	 System.out.print("정수를 입력하시오: ");
    	 a = sc.nextInt();
    	 System.out.print("정수를 입력하시오: ");
    	 b = sc.nextInt();
    	 
    	 int c = (a>b)?a:b;
    	 int d = (b>a)?a:b;
    	 int e = (a>b)? a/b : b/a;
    	 int f = (a>b)? a%b : b%a;
System.out.println(c+"을(를)"+d+"으로(로) 나눈몫은 "+e+
		"이고 나머지는 "+f+"입니다.");
    	}
}
